'use strict';

module.exports = app => {
    const { INTEGER, STRING, DATE, BIGINT, BOOLEAN, DECIMAL } = app.Sequelize;

    const OrderLike = app.model.define('order_like', {
        id: { type: BIGINT, primaryKey: true, autoIncrement: true },
        user_id: BIGINT,
        order_no: STRING(100),
        price: DECIMAL(10, 2),
        count: INTEGER,
        total_amount: DECIMAL(10, 2),
        payment: INTEGER,
        transaction_id: STRING(150),
        status: INTEGER,
        create_time: DATE,
        update_time: DATE,
        delete_time: DATE
    });

    return OrderLike;
}